package com.mrtan.vo;

import lombok.Data;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.Pattern;

@Data
public class RoleInsertVO {
    @NotBlank(message = "角色名不能为空")
    private String name;
    @NotBlank(message = "角色编码不能为空")
    @Pattern(regexp = "[a-zA-Z0-9_]{4,20}", message = "角色编码只能是4-20位的字母数字下划线")
    private String code;
    private String description;
}
